import request from "@/utils/request";

export const listCategoryAPI = () => {
  return request.get('/category');
};

export const addCategoryAPI = (categoryData) => {
  return request.post('/category', categoryData);
};

export const updateCategoryAPI = (categoryData) => {
  return request.put('/category', categoryData);
};

export const deleteCategoryAPI = (id) => {
  return request.delete('/category', { params: { id } });
};